Carbon


SetControlSupervisor

Header: Controls.h Carbon status: Supported

Routes mouse-down events to the embedder control.

OSErr SetControlSupervisor (
    ControlRef inControl, 
    ControlRef inBoss
);
inControl

A handle to an embedded control.

inBoss

A handle to the embedder control to which mouse-down events are to be routed.

function result

A result code.

DISCUSSION

The SetControlSupervisor function allows an embedder control to respond to mouse-down events occurring in its embedded controls.

An example of a standard control that uses this function is the radio group control. Mouse-down events in the embedded controls of a radio group are intercepted by the group control. (The embedded controls in this case must support radio behavior; if a mouse-down event occurs in an embedded control within a radio group control that does not support radio behavior, the control tracks normally and the group is not involved.) The group handles all interactions and switches the embedded control’s value on and off. If the value of the radio group changes, TrackControl or HandleControlClick will return the kControlRadioGroupPart part code. If the user tracks off the radio button or clicks the current radio button, kControlNoPart is returned.

VERSION NOTES

This function is available with Appearance Manager 1.0 and later.

AVAILABILITY

Supported in Carbon. Available in Mac OS 8.1 and later when Carbon 1.0.2 or later is present.


© 2000 Apple Computer, Inc. — (Last Updated 5/8/2000)